file(GLOB  RECONSTRUCTOR_SRC_FILES
    "*.f90"
)

set(sources-reconstructor-fpp 
    module_reconstructor_base.fpp
)
fypp_preprocess("${sources-reconstructor-fpp}" sources-reconstructor-postfpp)

include_directories(${PROJECT_SOURCE_DIR}/include)

set(RECONSTRUCTOR_SRC_FILES ${RECONSTRUCTOR_SRC_FILES} CACHE STRING INTERNAL)
set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/lib/reconstructor)
set(CMAKE_Fortran_MODULE_DIRECTORY ${PROJECT_SOURCE_DIR}/include/reconstructor)
add_library(reconstructor ${RECONSTRUCTOR_SRC_FILES} ${sources-reconstructor-postfpp})
target_link_libraries(reconstructor PkgConfig::PETSC PkgConfig::fortran_stdlib petsc_wrapper eos)
target_include_directories(reconstructor PUBLIC ${PROJECT_SOURCE_DIR}/include/reconstructor)
